import requestRank from '@/utils/requestRank';

// 引入
import type { resdata } from "./model/rankModel"
// 使用枚举包含所有的path
enum Api {
  Getrank1List = '/revision/rank/v4/rankTabs?sceneId=1',
  Getrank2List = '/revision/rank/v4/element'
}

//获取一级分类二级分类列表
export const Getrank1ListApi = () => {
  return requestRank.get<any, resdata>(Api.Getrank1List)
}
//获取二级分类一下的列表
export const Getrank2ListApi = (rankingId: number) => {
  return requestRank.get<any, any>(Api.Getrank2List + `?rankingId=${rankingId}`)
}

